package com.room.mapper;

import com.room.pojo.Apartment;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface ApartmentMapper {
    int deleteByPrimaryKey(String apartmentId);

    int insert(Apartment record);

    int insertSelective(Apartment record);

    Apartment selectByPrimaryKey(String apartmentId);

    int updateByPrimaryKeySelective(Apartment record);

    int updateByPrimaryKey(Apartment record);

    List<Apartment> getApartmentByPage(@Param("start")Integer start, @Param("size") Integer size);

    Long getApartmentCount();

    //获取所有的公寓，用来初始化下拉菜单数据
    List<Apartment> getAllApartment();

    //根据id删除公寓数据
    int deleteApartById(@Param("ids")String[] ids);

    //获取最大编号
    String getMaxId();
}